# -*- coding:utf-8 -*-

class Student(object):

    def __init__(self,name,score):
            self.__name = name
            self.__score = score

    def print_self(self):
        print '%s %s' % (self.__name,self.__score)

    def get_grade(self):
        if self.__score >= 80:
            print 'A'
        elif self.__score >= 70:
            print 'B'
        else:
            print 'C'

    def get_name(self):
        return self.__name

    def get_score(self):
        return self.__score

    def set_name(self,name):
        self.__name = name

    def set_score(self,score):
        if 0<= score <= 100:
            self.score = score
        else:
            raise ValueError('bad value')

bart = Student('liyan',88)
bart.print_self()
bart.get_grade()
bart.set_name('liyan wo xiang ni le')
bart.set_score(101)
print bart.get_name()
print bart.get_score()
